//
//  CViewController.m
//  UI_19_H
//
//  Created by yanghuiyan on 16/1/29.
//  Copyright © 2016年 YHY. All rights reserved.
//

#import "CViewController.h"
#import "UIImageView+WebCache.h"
#import "DetailModel.h"
@interface CViewController ()

@end

@implementation CViewController


-(instancetype)initWithDetailModel:(DetailModel *)detailmodel {
    self = [super init];
    if (self) {
        _detailModel = [[DetailModel alloc] init];
    }
    return self;
}

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
    self.view.backgroundColor = [UIColor whiteColor];
    
    [self.moveView sd_setImageWithURL:[NSURL URLWithString:_detailModel.imageModel.large]];
    self.titleLabel.text = _detailModel.title;
    
}

- (void)touchesBegan:(NSSet<UITouch *> *)touches withEvent:(UIEvent *)event {
    [self dismissViewControllerAnimated:YES completion:^{
        
    }];
}
- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
